package com.demo.burt.mysql.tech.write.dao;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import com.demo.burt.dataobject.TestOrder;

/**
 * <p>
 * 订单写Mapper 接口
 * </p>
 *
 * @author luowei1
 * @since 2018-12-12
 */
public interface TestOrderMapper extends BaseMapper<TestOrder> {

    /**
     * 批量保存订单
     *
     * @param orders 订单对象集合
     * @return 影响行数
     */
    Integer saveOrderBatch(@Param("orders") List<TestOrder> orders);

    /**
     * <p>
     * 取消订单
     * </p>
     * 
     * @param orderIds 订单id
     * @param currentStatus 订单当前状诚
     * @return 影响行数
     */
    Integer cancelOrders(@Param("orderIds") List<Long> orderIds, @Param("currentStatus") int currentStatus);
}
